package de.koller.density.render;

import de.koller.aframe.gl.ATexture;
import de.koller.aframe.gl.ATexture.ITextureBuilder;
import de.koller.oceanFramework.gl.util.ParticleTexture;
import java.awt.Point;

public class CircleTexture extends ATexture implements ITextureBuilder {

	@Override
	protected void setUp( TextureParameters tparam ) {
		tparam.builder = this;
		tparam.size = 128;
	}

	@Override
	public void build( ParticleTexture texture ) {
		texture.clear( 0xffffffff );
		
		for( int x = 0; x < texture.getWidth(); x++ )
			for( int y = 0; y < texture.getHeight(); y++ )
				if( Point.distance( x, y, 64, 64 ) < 60 )
					texture.setPixel( 0xff000000, x, y );
	}
	
	
	
}
